<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width,initial-scale=1" />
		<meta http-equiv="X-UA-Compatible" content="IE=Edge">
		<title>财富共赢</title>
		<!--bootstrap-css-->
		<link rel="stylesheet" type="text/css" href="__PUBLIC__/Ak/lib/bootstrap/css/bootstrap.min.css" />
		<link rel="stylesheet" type="text/css" href="__PUBLIC__/Ak/css/base.css" />
		<link rel="stylesheet" type="text/css" href="__PUBLIC__/Ak/css/style.css" />
		<link href="__PUBLIC__/upload/css.css" rel="stylesheet" media="screen" type="text/css">
		<!--[if lte IE 9]>
		    <script type="text/javascript" src="__PUBLIC__/Ak/lib/html5shiv/html5shiv.min.js" ></script>
		    <script type="text/javascript" src="__PUBLIC__/Ak/Dt/lib/html5shiv/html5shiv-printshiv.min.js" ></script>
	    <![endif]-->
		<script type="text/javascript" src="__PUBLIC__/Ak/lib/bootstrap/js/jquery.min.js"></script>

		<script type="text/javascript" src="__PUBLIC__/Ak/lib/bootstrap/js/bootstrap.min.js"></script>
		<script type="text/javascript" src="__PUBLIC__/Ak/js/yxk.js"></script>
		<script type="text/javascript" src="__PUBLIC__/Dt/lib/jedate/jedate.min.js"></script>
		<script type="text/javascript" src="__PUBLIC__/upload/jquery.form.js"></script>
		<script type="text/javascript" src="__PUBLIC__/upload/upload.js"></script>
		<script>
			//倒计时
			function daojishi(times, ti, i) {
				ti = setInterval(daoji, 1000);

				function daoji() {

					if(times <= 0) {
						clearInterval(ti);
						$('#lasttime' + i).html(0);
						return;
					} else {
						times--;
					}
					var hours = parseInt(times / 3600) < 10 ? "0" + parseInt((times / 3600)) : parseInt(times / 3600);
					var second = times % 60 < 10 ? "0" + (times % 60) : times % 60;
					var minutes = ((times - hours * 3600 - second) / 60) //- < 10 ? "0"+ (times-second)/60 : ((times-second)/60);
					$('#lasttime' + i).html(hours + ":" + minutes + ":" + second);

				}

			}
		</script>
	</head>

	<body>
		<div id="main">
			<header>
				<div class="top_bar">
					<a href="javascript:;" id="retu"><i class="glyphicon glyphicon-menu-left"></i></a>
					<p class="text-center m0 h4">申请排单</p>
				</div>
				<div style="height: 40px;"></div>
			</header>

			<section class="sec ls">
				<table class="table">
					<volist name="room" id="vo">
					<tr>
						<td>
							<p>排单号：{$vo.orderid}</p>
							<p>{$vo.createtime|date='Y-m-d H:i:s',###}</p>
						</td>
						<td>
							<p class="text_4CD964">RMB {$vo.price}</p>
							<p>状态：
								<span class="color-d84a38">
		                            <switch name="vo.status">
		                                <case value="0">等待匹配</case>
		                                <case value="1">等待打款</case>
		                                <case value="2">等待收款</case>
		                                <case value="3">完成</case>
		                            </switch>
								</span>
							</p>
						</td>
					</tr>
					
					<volist name="vo.sub" id="vo1">
					<tr>
						<td>
							<p>匹配用户：{$vo1.username}</p>
							<p>{$vo.begintime|date='Y-m-d H:i:s',###}</p>
						</td>
						<td>
							<p class="text_4CD964">RMB
								<if condition="vo.price gt vo1.price">
									<php>if($vo['price']>$vo1['price']){</php>
									{$vo1.price}
									<php>}else{</php>
									{$vo.price}
									<php>}</php>
								</if>
							</p>
							<p>状态：
								<switch name="vo1.status">
									<case value="1">
										等待确认打款
									</case>
									<case value="2">
										已经打款
									</case>
									<case value="3">
										完成
									</case>
								</switch>
							</p>
						</td>
					</tr>
					
					<tr>
						<td colspan="2">
							<table class="table">
								<tr>
									<td width="120px" align="left">云付通姓名：</td>
									<td align="left">{$vo1.bankname}</td>
								</tr>
								<tr>
									<td align="left">云付通账号：</td>
									<td align="left">{$vo1.bankcode}/ </td>
								</tr>
								<tr>
									<td align="left">联络接收人：</td>
									<td align="left">{$vo1.realname}:{$vo1.mobile}</td>
								</tr>
								<tr>
									<td align="left">联络推荐人：</td>
									<td align="left">{$vo1.trealname}:{$vo1.tmobile}</td>
								</tr>
								<tr>
									<td align="left">打款倒计时：</td>
									<td align="left">
										<if condition="$vo1.status eq 1">
											<div id="lasttime{$vo1.id}"> </div>
											<script>
												daojishi("<php>echo 6*3600-(time()-$vo1['begintime']);</php>", 'it{$vo1.id}', '{$vo1.id}');
											</script>
											<else /> 0
										</if>
									</td>
								</tr>
								<tr>
									<td align="left">凭据图片：</td>
									<td align="left">
										<div id="img{$vo1.id}" class="imgcontent">
											<if condition="$vo1.pic eq ''">
												<div class="btnimg">

													<img src="__PUBLIC__/upload/bg.jpg" class="btnbg" style="width:100px;height:100px;left:0px;z-Index:-1;" />

													<span class="btnspan"></span>
													<input id="fileupload{$vo1.id}" type="file" name="mypic">
	
													<div class="progress"><span class="bar"></span><span class="percent">0%</span ></div>
												</div>
	                                        	<div style="clear:both;"></div>
	                                        	<p style="font-size:9px; float:left;margin-top:5px;">上传图片大小不能超过1M</p>
	                                        	<a href="#" id="bigimg{$vo1.id}" style="display: none;" target="_blank">查看大图</a>
	                                        	<input type="hidden" id="img{$vo1.id}url" name=""/>
	                                        	<script>upload("img{$vo1.id}","fileupload{$vo1.id}");</script>
												<else />
												<div class="btnimg">
													<img src="{$vo1.pic}" class="btnbg" style="width:100px;height:100px;left:0px;z-Index:-1;" />
												</div>
											</if>
                                    	</div>
                            		</td>
                        		</tr>
                    		</table>
						</td>
					</tr>
					<tr>
						<td id="pull{$vo.id}_{$vo1.id}" colspan="2" align="left">
							<switch name="vo1.status">
								<case value="1">
									请输入安全密码：<input id="password{$vo.id}_{$vo1.id}" type="password" name="password{$vo.id}_{$vo1.id}" placeholder="输入安全密码"><br><br>
									<button type="button" id="button{$vo.id}_{$vo1.id}" class="btn btn-primary" onclick="pipeiok('{$vo.id}','{$vo1.id}');">确认打款</button>
								</case>
								<case value="2">已经打款</case>
								<case value="3">订单已经完成</case>
							</switch>
						</td>
					</tr>
					</volist>
					<tr><td colspan="2"></td></tr>
					</volist>
				</table>
			</section>
			<include file="./Tm/Ak/Menu.html" />
		</div>
	</body>

</html>

<script src="__PUBLIC__/Ak/js/ltohelp.js?0.0.1" type="text/javascript" charset="utf-8"></script>